#pragma once 
#include <iostream>
#include <string>

class Channel
{
public:
    Channel(int fd,int pid) 
        :_wfd(fd),
        _pid(pid)
        {
            _name = "child write: " + std::to_string(fd)  + ", pid: " + std::to_string(pid);
        }
    ~Channel() 
        {}
        int ID()
        {
            return _wfd;
        }
        std::string Name()
        {
            return _name;
        }
        int Pid()
        {
            return _pid;
        }
private:
    int _wfd; //写端口
    std::string _name;    
    int _pid;
};